<%--
  Created by IntelliJ IDEA.
  User: TY
  Date: 2018/4/3
  Time: 16:18
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<script src="/js/jquery-3.3.1.min.js"></script>
<html>
<head>
    <title>Title</title>
</head>
<body>
    <input type="button" value="测试" onclick="sendJson()">
</body>
<script>
function sendJson() {
    $.ajax({
        type : "post",
        url : "superadmin/requestOpenid",
        data:'{"openid":"4445","nickname":"kimi","level":11,"avatarurl":"44","totaltime":0,"wintime":0,"status":-1}',//ids是数组形式
        traditional:true,//必须加上设置为true
        contentType:"application/json;charset=utf-8",
        success : function(result) {
            if(result=="success")
            {
                alert("success");
            }

        },
    });
}
</script>
</html>
